<?php
	list($sql,$all_page) = splitPage("`tbl_locations`","1 AND `status` != '2' ORDER BY `location_id` ASC", 30, $_GET['p']);
	$strPage = fetchPage($all_page,$_GET['p']);
	$query = mysql_query($sql);
	$tp->block('result');
	while($result = mysql_fetch_assoc($query)) {
		$location_id	= $result['location_id'];
		$title		= $result['title'];
		$status		= $result['status'] ? 'publish' : 'draft';
		$date		= formatDate($result['date'], 'd/m/Y');
		$tp->apply();
	}
	mysql_free_result($query);
?>